// my/index/index.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
    imgUrls: [
      '../../image/nav1.png',
      'http://img002.fview.cn/Public/upload/block/f98f9306ad258831f18332f8ba7e759e.JPG'
    ],
    indicatorDots: false,
    autoplay: false,
    interval: 5000,
    duration: 1000,
    phone:'',
    values:'',
    iphone:''
  },
  changeIndicatorDots: function (e) {
    this.setData({
      indicatorDots: !this.data.indicatorDots
    })
  },
  changeAutoplay: function (e) {
    this.setData({
      autoplay: !this.data.autoplay
    })
  },
  intervalChange: function (e) {
    this.setData({
      interval: e.detail.value
    })
  },
  durationChange: function (e) {
    this.setData({
      duration: e.detail.value
    })
  },
 
  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {

  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {
    let that = this;
    wx.getSystemInfo({
      success(res) {
        that.setData({
          phone: res.model
        });
      
      }
    })
  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {

  },
  soufun() {
    wx.navigateTo({
      url: '../sou/sou',
    })
  },
  youfun() {
    wx.navigateTo({
      url: '../you/you',
    })
  },
  listfun(e) {
   
    this.setData({
      values: e.currentTarget.dataset.hi
    });
    // console.log(this.data.values)
    wx.navigateTo({
      url: '../list/list?key=' + this.data.values,
    })
  },
  xiangfun(e){
    // console.log(e)
    this.setData({
      iphone: e.currentTarget.dataset.pho
    });
    wx.navigateTo({
      url: '../xiang/xiang?key=' + this.data.iphone,
    })
  },
  movefun() {
    wx.navigateTo({
      url: '../list/list?key=phone',
    })
  },
  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  }
})